package reusing;

class  WaterSorce{
	private String s;
	WaterSorce(){
		System.out.println("WaterSorce()");
		s = "Constructed";
	}
	public String toString() {
		return s;
	}
}

public class SprinklerSystem {

	private String valve1,valve2,valve3,valve4;
	private WaterSorce source = new WaterSorce();
	private int i;
	private float f;
	public String toString() {
		return 
			"valve1 = " + valve1 + " " +
			"valve2 = " + valve2 + " " +
			"valve3 = " + valve3 + " " +
			"valve4 = " + valve4 + "\n" +
			"i = " + i + " " + "f = " + f + " " +
			"source = " + source;
	}
	
	public static void main(String[] args) {
		SprinklerSystem sprinklers = new SprinklerSystem();
		System.out.println(sprinklers);
	}
}
